import configparser

path = r"C:\Users\谭杰\PycharmProjects\pythonProject2\config\setting.ini"


def read_ini():
    config = configparser.ConfigParser()
    config.read(path, encoding='utf-8')
    return config

get_ini=read_ini()

print(read_ini()['host']['api_test_host'])
